package com.fancy.user.dto.response;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.Date;

@Data
@ApiModel("用户详情响应")
public class UserDetailVO {
    @ApiModelProperty(value = "用户ID", example = "12345")
    private Long userId;
    
    @ApiModelProperty(value = "用户名", example = "testuser")
    private String username;
    
    @ApiModelProperty(value = "邮箱", example = "test@example.com")
    private String email;
    
    @ApiModelProperty(value = "手机号", example = "13800138000")
    private String phone;
    
    @ApiModelProperty(value = "昵称", example = "测试用户")
    private String nickname;
    
    @ApiModelProperty(value = "头像URL", example = "/images/avatars/12345.jpg")
    private String avatarUrl;
    
    @ApiModelProperty(value = "性别（1-男，2-女，3-保密）", example = "1")
    private Integer gender;
    
    @ApiModelProperty(value = "生日", example = "1990-01-01")
    private Date birthday;
    
    @ApiModelProperty(value = "个人介绍", example = "热爱音乐的普通用户")
    private String introduction;
    
    @ApiModelProperty(value = "爱好", example = "流行音乐,摇滚")
    private String hobby;
    
    @ApiModelProperty(value = "等级信息")
    private LevelInfo levelInfo;
    
    @ApiModelProperty(value = "会员信息")
    private MembershipInfo membershipInfo;
    
    @ApiModelProperty(value = "统计信息")
    private StatisticsInfo statisticsInfo;
    
    @Data
    @ApiModel("等级信息")
    public static class LevelInfo {
        @ApiModelProperty(value = "当前等级", example = "2")
        private Integer currentLevel;
        
        @ApiModelProperty(value = "当前经验值", example = "150")
        private Integer currentExp;
        
        @ApiModelProperty(value = "升级所需经验", example = "300")
        private Integer requiredExp;

        @ApiModelProperty(value = "等级名称", example = "黄金会员")
        private String levelName;  // 新增字段


    }
    
    @Data
    @ApiModel("会员信息")
    public static class MembershipInfo {
        @ApiModelProperty(value = "会员类型（VIP/FAN）", example = "VIP")
        private String type;

        @ApiModelProperty(value = "会员类型名称", example = "黑胶会员")
        private String typeName;  // 新增字段

        @ApiModelProperty(value = "开始时间", example = "2023-01-01 12:00:00")
        private Date startTime;
        
        @ApiModelProperty(value = "结束时间", example = "2024-01-01 00:00:00")
        private Date endTime;
        
        @ApiModelProperty(value = "状态（1-有效，0-过期）", example = "1")
        private Integer status;
    }
    
    @Data
    @ApiModel("统计信息")
    public static class StatisticsInfo {
        @ApiModelProperty(value = "粉丝数", example = "1000")
        private Integer followerCount;
        
        @ApiModelProperty(value = "关注数", example = "200")
        private Integer followingCount;
        
        @ApiModelProperty(value = "收藏数", example = "50")
        private Integer collectionCount;
    }
}